package com.jy.adscm.wechat.mapper.mysql;

import com.jy.adscm.wechat.bean.WechatUser;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author zyl
 * @since 2019-09-23
 */
public interface WechatUserMapper extends BaseMapper<WechatUser> {
     @Select("select id,name,phone,plasma_station_id As plasmaStationId,create_time as createTime,longitude,latitude from wechat_user where openid=#{openId}")
    WechatUser selectByOpenId(@Param("openId") String openId);

    List<WechatUser> selectByRoleId(@Param("roleId") String roleId, @Param("pid") String pid);
}
